<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title> - 反馈详情</title>
    <meta name="keywords" content="">
    <meta name="description" content="">
    <link rel="shortcut icon" href="favicon.ico"> <link href="/Public/css/bootstrap.min.css?v=3.3.6" rel="stylesheet">
    <link href="/Public/css/font-awesome.css?v=4.4.0" rel="stylesheet">
    <link href="/Public/css/animate.css" rel="stylesheet">
    <link href="/Public/css/style.css?v=4.1.0" rel="stylesheet">
    <style>
        .project-people img {
            width: 100px;
            height: 100px;
        }

    </style>
    <style>
        .font{
            font-size: initial;
        }
    </style>
</head>

<body class="gray-bg">
<div class="row">

        <div class="col-sm-3">
            <div class="wrapper wrapper-content project-manager">
                <h4>回复</h4>
                <p class="small font-bold">
                    <textarea style="width: 90%" class="input_bg_color" name="back_content" id="content" cols="70" rows="12" placeholder="请输入内容"></textarea>
                </p>
                <div class="m-t-md">
                    <a href="javascript:;" onclick="edit_message()"  style="width: 200px" class="btn btn-xs btn-primary">添加</a>
                </div>
            </div>
        </div>

</div>

<script src="/Public/js/jquery.min.js?v=2.1.4"></script>
<script src="/Public/js/bootstrap.min.js?v=3.3.6"></script>
<script src="/Public/js/content.js?v=1.0.0"></script>
<script src="/Public/admin/js/plugins/jquery.colorbox-min.js"></script>
<script src="/Public/admin/js/ajaxfileupload.js"></script>
<script src="/Public/admin/js/plugins/layer/layer.min.js"></script>
<script>

    var content="<{$content}>";
    $("#content").val(content);

    function loselay() {
        location.reload();
    }

    function edit_message() {

        var index = layer.load(1, {
            shade: [0.1, '#fff'] //0.1透明度的白色背景
        });

        var edit_content=  $("#content").val();
        var url="<{$SRVER_NAME}>/admin.php/Outbound/edit_content";
        var id="<{$id}>";
        var vid="<{$vid}>";
        if (edit_content == "") {
            layer.close(index);
            layer.alert("不能为空！\r\n", {
                title: '提示框',
                icon: 0,
            });
            return false;
        }

        $.post(url, {
            id:id,
            edit_content: edit_content,

        }, function (data) {

            if (data.code == "1001") {

             layer.alert(data.result, {title: '提示框', icon: 1}, function () {
                 setTimeout(window.parent.loselay(), 5000);
//                 var index1 = parent.layer.getFrameIndex(window.name);
//                 parent.layer.close(index1);
//                 parent.location.reload();
//                 layer.close(index);
//                     window.location.href='<{$SRVER_NAME}>/admin.php/Outbound/list_details?vid='+vid;
                    }
                );


            }
            else {
                layer.alert(data.result, {title: '提示框', icon: 0});
            }

        });
        layer.close(index);

    }


</script>




</body>

</html>
